package com.carleasoft.mps.security.permission.feign;

import com.carleasoft.mps.core.constant.ServiceNameConstants;
import com.carleasoft.mps.core.perm.AllCache;
import com.carleasoft.mps.core.result.R;
import com.carleasoft.mps.security.permission.bean.InformationLibrary;
import com.carleasoft.mps.security.permission.bean.InformationLibraryPo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Repository;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(value = ServiceNameConstants.USER_SERVER)
@Repository
public interface RemoteAllCacheService {

    @PostMapping("/adu/login/buildUser/{userAccount}")
    R<AllCache> buildUser(@PathVariable(name="userAccount") String userAccount);

    @PostMapping("/adu/information/selectById")
    public R<InformationLibrary> selectById(@RequestBody InformationLibraryPo informationLibraryPo);

}
